<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="/common/common.jsp"%>
<%@ page import="com.chanyachting.emall.util.*" %>
<%@ page import="java.util.*" %>

<%@ page import="com.chanyachting.emall.domain.*" %>
<%@ page import="com.chanyachting.emall.dao.*" %>
<%@ page import="com.chanyachting.emall.util.RequestUtil" %>
<%@ page import="com.chanyachting.emall.service.*" %>
<%@ page import="com.chanyachting.emall.serviceImpl.*" %>



<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="keywords" content="" /> 
<meta name="description" content="" />
<link href="css/import.css" type="text/css" rel="stylesheet" />
<title></title>


<script type="text/javascript" src="<%=root %>/js/jquery-1.3.2.min.js" charset="utf-8">//ADCRM</script>
<script type="text/javascript" src="<%=root %>/js/jquery.form.js" charset="utf-8">//ADCRM</script>

<script language="javascript" type="text/javascript">

	$(function(){

		$.ajaxSetup ({
		    cache: false //关闭AJAX相应的缓存
		});

		});


	//创建普通类型商品
	function saveproduct(theForm){

		//alert(theForm.action);

		options={
			    url:theForm.action,
			    success: function(data){
					
					alert("创建成功！");
				    }
			  };
				
		$(theForm).ajaxSubmit(options);
	}

</script>


</head>


<%

	//从session中获得公司对象
	RequestUtil ru=new RequestUtil(request);
	
	Company company=(Company)ru.getSessionObject(CompanyService.COMPANY_IN_SESSION,new Company());

	String id = ru.getParameter("id","0").trim();
	
	String actionName = "";
	String actionType = "";
	
	if ("0".equals(id)) {
		actionName = "/memberBackend/dockCreate.do";
		id = "";
		actionType = "发布";
	} else {
		actionName = "/memberBackend/dockUpdate.do";
		actionType = "修改";
	}
%>

<body>
<div class="tab_box">
	<div class="tab_menu">
 
        <a href="product_dock_create.jsp" class="current"><%=actionType %>码头及俱乐部展示</a>
   
    </div>
	<div class="tab_submenu">
	  <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="50%"><span class="mu_title"><a href="product_dock_create.jsp">基本信息</a> <a href="in3_3_b.html">图文信息</a></span></td>
          <td align="right"><strong><a href="#">预览</a><a href="#">打印</a><a href="#">导出</a></strong></td>
        </tr>
      </table>
	</div>
</div>

<form action="<%=root %><%=actionName %>" method="post" enctype="multipart/form-data" name="form3" id="form3">

<input type="hidden" name="companyId" value="<%= company.getId() %>" />
<input type="hidden" name="point" value="0" />
<input type="hidden" name="type" value="03" />
<input type="hidden" name="status" value="00" />
<input type="hidden" name="id" value="<%=id %>" />

  <div id="bigbox">
    <table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td width="50%"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td width="100" height="28" align="right">产品名称：</td>
            <td colspan="2"><label>
              <input type="text" name="name" id="textfield47" value="${dockForm.dock.name}" />
            </label></td>
          </tr>
          <tr>
            <td height="28" align="right">市场售价：</td>
            <td width="80"><label>
              <select name="dockType" id="select">
                <option value="00">产品类型</option>
              </select>
            </label></td>
            <td><input type="text" name="firstPrice" id="textfield48" value="${dockForm.dock.firstPrice}" /></td>
          </tr>
          <tr>
            <td height="28" align="right">&nbsp;</td>
            <td>&nbsp;</td>
            <td><input type="text" name="secondPrice" id="textfield5" value="${dockForm.dock.secondPrice}" /></td>
          </tr>
        </table></td>
        <td valign="bottom"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
            <tr>
              <td height="28" align="right">&nbsp;</td>
              <td><img src="images/pp_03.gif" width="128" height="86" /></td>
            </tr>
            <tr>
              <td width="100" height="28" align="right">显示图片：</td>
              <td><label>
                <input type="file" name="fileField5" id="fileField5" />
              </label></td>
            </tr>
        </table></td>
      </tr>
      <tr>
        <td valign="bottom">&nbsp;</td>
        <td valign="bottom">&nbsp;</td>
      </tr>
    </table>
    <table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td colspan="5" class="td_top">&nbsp;</td>
      </tr>
      <tr>
        <td width="100" align="left"><div class="ptitle">主要参数</div></td>
        <td width="230" height="28" align="right">航海纬度：</td>
        <td colspan="3"><label>
          <input type="text" name="dimensionality" id="textfield33" value="${dockForm.dock.dimensionality}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">水上泊位数量：</td>
        <td colspan="3"><label>
          <input type="text" name="berthNumber" id="textfield34" value="${dockForm.dock.berthNumber}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">干仓数量：</td>
        <td colspan="3"><label>
          <input type="text" name="roomNumber" id="textfield54" value="${dockForm.dock.roomNumber}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">泊位尺寸(最小至最大)：</td>
        <td colspan="3"><label>
          <input type="text" name="berthArea" id="textfield55" value="${dockForm.dock.berthArea}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">最大宽度：</td>
        <td colspan="3"><input type="text" name="maxdepth" id="textfield56" value="${dockForm.dock.maxdepth}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">水深：</td>
        <td colspan="3"><input type="text" name="depthOfWater" id="textfield57" value="${dockForm.dock.depthOfWater}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">海岸/内陆：</td>
        <td colspan="3"><input type="text" name=seacoast id="textfield58" value="${dockForm.dock.seacoast}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">泊位类型：</td>
        <td colspan="3"><input type="text" name="berthType" id="textfield59" value="${dockForm.dock.berthType}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">项目类型：</td>
        <td colspan="3"><input type="text" name="itemType" id="textfield60" value="${dockForm.dock.itemType}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">成立时间：</td>
        <td colspan="3"><input type="text" name="buildTime" id="textfield60" value="${dockForm.dock.buildTime}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">现场地点：</td>
        <td colspan="3"><label>
          <input type="text" name="address" id="textfield62" value="${dockForm.dock.address}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">俱乐部会所：</td>
        <td colspan="3"><label>
          <input type="text" name="club" id="textfield63" value="${dockForm.dock.club}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">水岸配套建筑：</td>
        <td colspan="3"><label>
          <input type="text" name="waterBuilding" id="textfield64" value="${dockForm.dock.waterBuilding}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">总面积：</td>
        <td colspan="3"><label>
          <input type="text" name="allArea" id="textfield65" value="${dockForm.dock.allArea}" />
        </label></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">水域面积：</td>
        <td colspan="3"><input type="text" name="waterArea" id="textfield66" value="${dockForm.dock.waterArea}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">距离市中心：</td>
        <td colspan="3"><input type="text" name="centerDistance" id="textfield67" value="${dockForm.dock.centerDistance}" /></td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">距离机场：</td>
        <td colspan="3"><label>
          <input type="text" name="airDistance" id="textfield68" value="${dockForm.dock.airDistance}" />
        </label></td>
      </tr>
    
      <tr>
        <td colspan="5">&nbsp;</td>
      </tr>
      <tr>
        <td colspan="5" class="td_top">&nbsp;</td>
      </tr>
      <tr>
        <td align="left"><div class="ptitle">设施</div></td>
        <td height="28" align="right">&nbsp;</td>
        <td width="131"><label>便利和旅游设施</label></td>
        <td width="92" align="right">&nbsp;</td>
        <td width="147">游艇码头设施</td>
      </tr>
      <tr>
        <td align="left">&nbsp;</td>
        <td height="28" align="right">&nbsp;</td>
        <td><input type="checkbox" name="checkbox13" id="checkbox10" />
综合商店</td>
        <td align="right">&nbsp;</td>
        <td><input type="checkbox" name="checkbox" id="checkbox" />
维护保养</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><label>
          <input type="checkbox" name="checkbox10" id="checkbox11" />
          航海商店</label></td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox2" id="checkbox2" />
下水坡道</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><label>
          <input type="checkbox" name="checkbox10" id="checkbox12" />
          淋浴</label></td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox3" id="checkbox3" />
搬运设施</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox13" />
          公厕</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox4" id="checkbox4" />
电源</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox14" />
          客房出租</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox5" id="checkbox5" />
冬季贮藏</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox15" />
          餐馆</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox6" id="checkbox6" />
航海配件商店</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox16" />
          游泳池</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox7" id="checkbox7" />
汽油</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox17" />
          无线网络</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox8" id="checkbox8" />
柴油</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox13" />
          有线电视</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox9" id="checkbox9" />
水</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox14" />
          旅游景点</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox11" id="checkbox19" />
污水污油处理</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox15" />
          露营地</td>
        <td>&nbsp;</td>
        <td><input type="checkbox" name="checkbox12" id="checkbox18" />
豪华游艇设施</td>
      </tr>
      <tr>
        <td height="28" colspan="2">&nbsp;</td>
        <td><input type="checkbox" name="checkbox10" id="checkbox16" />
          钓鱼点</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
      </tr>
      <tr>
        <td height="28" colspan="2" align="right">产品类型：</td>
        <td colspan="3"><label>
          <select name="dockType" id="select5">
            <option value="新泊租售" selected="selected">新泊租售</option>
            <option value="泊位出租">泊位出租</option>
            <option value="泊位销售">泊位销售</option>
            <option value="新会籍销售">新会籍销售</option>
            <option value="二手会籍销售">二手会籍销售</option>
          </select>
        </label></td>
      </tr>
      <tr>
        <td colspan="2" align="right">&nbsp;</td>
        <td colspan="3">&nbsp;</td>
      </tr>
      <tr>
        <td colspan="5" align="right" class="td_top">&nbsp;</td>
      </tr>
      <tr>
        <td height="28" align="left"><div class="ptitle">会藉销售</div></td>
        <td align="right">個人會藉：</td>
        <td colspan="3"><label>
          <input type="text" name=personMembership id="textfield70" value="${dockForm.dock.personMembership}" />
        </label></td>
      </tr>
      <tr>
        <td height="28">&nbsp;</td>
        <td align="right">公司會藉：</td>
        <td colspan="3"><label>
          <input type="text" name="companyMembership" id="textfield71" value="${dockForm.dock.companyMembership}" />
        </label></td>
      </tr>
      <tr>
        <td height="28">&nbsp;</td>
        <td align="right">月費：</td>
        <td colspan="3"><label>
          <input type="text" name="monthFees" id="textfield72" value="${dockForm.dock.monthFees}" />
        </label></td>
      </tr>
      <tr>
        <td height="28">&nbsp;</td>
        <td align="right">轉提名人費用：</td>
        <td colspan="3"><label>
          <input type="text" name="turnoverFees" id="textfield73" value="${dockForm.dock.turnoverFees}" />
        </label></td>
      </tr>
      <tr>
        <td height="28">&nbsp;</td>
        <td align="right">其它：</td>
        <td colspan="3"><label>
          <input type="text" name="other" id="textfield74" value="${dockForm.dock.other}" />
        </label></td>
      </tr>

      <tr>
        <td colspan="2" align="right">&nbsp;</td>
        <td colspan="3">&nbsp;</td>
      </tr>
      <tr>
        <td colspan="5" class="td_top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td colspan="2">&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td height="28" colspan="2"><div class="ptitle">泊位租售</div></td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td width="18">&nbsp;</td>
            <td width="138" height="28" align="center"><p>尺寸    (feet) </p></td>
            <td width="68" align="center"><p>25-32 </p></td>
            <td width="68" align="center"><p>32-37 </p></td>
            <td width="68" align="center"><p>38-42 </p></td>
            <td width="68" align="center"><p align="center">43-49 </p></td>
            <td width="68" align="center"><p>50-60 </p></td>
            <td width="68" align="center"><p align="center">61-70 </p></td>
            <td width="68" align="center"><p>71-80 </p></td>
            <td width="68" align="center"><p>81-120 </p></td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td height="28" align="center"><p>租金（元/年） </p></td>
            <td width="68" align="center"><input name="textfield31" type="text" id="textfield28" size="4" /></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield30" type="text" id="textfield27" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield27" type="text" id="textfield24" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield26" type="text" id="textfield23" size="4" />
            </p></td>
            <td width="68" align="center"><input name="textfield21" type="text" id="textfield20" size="4" /></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield20" type="text" id="textfield19" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield18" type="text" id="textfield17" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield16" type="text" id="textfield15" size="4" />
            </p></td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td height="28" align="center"><p>售价（元/年） </p></td>
            <td width="68" align="center"><input name="textfield32" type="text" id="textfield29" size="4" /></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield29" type="text" id="textfield26" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield28" type="text" id="textfield25" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield25" type="text" id="textfield22" size="4" />
            </p></td>
            <td width="68" align="center"><input name="textfield23" type="text" id="textfield21" size="4" /></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield19" type="text" id="textfield18" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield17" type="text" id="textfield16" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield15" type="text" id="textfield14" size="4" />
            </p></td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td height="28" align="center"><p>访问价</p></td>
            <td width="68" align="center"><label>
              <input name="textfield2" type="text" id="textfield" size="4" />
            </label></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield8" type="text" id="textfield2" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield9" type="text" id="textfield3" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield10" type="text" id="textfield4" size="4" />
            </p></td>
            <td width="68" align="center"><input name="textfield11" type="text" id="textfield9" size="4" /></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield12" type="text" id="textfield10" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield13" type="text" id="textfield12" size="4" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input name="textfield14" type="text" id="textfield13" size="4" />
            </p></td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td height="28" align="center"><p>选择两种规格在前台显示</p></td>
            <td width="68" align="center"><label>
              <input type="checkbox" name="checkbox25" id="checkbox25" />
            </label></td>
            <td width="68" align="center"><p align="center">
              <input type="checkbox" name="checkbox14" id="checkbox26" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input type="checkbox" name="checkbox15" id="checkbox27" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input type="checkbox" name="checkbox16" id="checkbox28" />
            </p></td>
            <td width="68" align="center"><input type="checkbox" name="checkbox17" id="checkbox29" /></td>
            <td width="68" align="center"><p align="center">
              <input type="checkbox" name="checkbox18" id="checkbox30" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input type="checkbox" name="checkbox19" id="checkbox31" />
            </p></td>
            <td width="68" align="center"><p align="center">
              <input type="checkbox" name="checkbox20" id="checkbox32" />
            </p></td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td>&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
            <td align="center">&nbsp;</td>
          </tr>
        </table></td>
      </tr>
      <tr>
        <td colspan="5" class="td_top">&nbsp;</td>
      </tr>
      <tr>
        <td height="28" colspan="5" align="left"><table width="700" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td height="28" align="right">选择发布频道：</td>
            <td width="550"><select name="channelId" id="select9">
	      	<option value="0">请选择</option>
	      	<%
	      		ChannelDAO cDao = new ChannelDAO();
	      		Channel parentC = cDao.getChannelByType("04");  //码头俱乐部
	      		if (parentC != null) {
	      			List<Channel> subChannel = cDao.getSubChannel(parentC);
	      			for (Channel tmpC:subChannel) {
	      				%>
	      				<option value="<%=tmpC.getId() %>"><%=tmpC.getName() %></option>
	      				<%
	      			}
	      		}
      		%>
	      </select></td>
          </tr>
          <tr>
            <td width="150" height="28" align="right">选择发布码头类型：</td>
            <td><select name="select9" id="select6">
              </select>
                <input type="radio" name="radio" id="radio3" value="radio" />
              立即发布
              <input type="radio" name="radio" id="radio4" value="radio2" />
              待上架 　 <span class="txt_gray">什么是待上架? 说明：待上架的内容不在前台显示</span></td>
          </tr>
        </table></td>
      </tr>
    </table>
    <table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td align="center" class="td_bottom">&nbsp;</td>
      </tr>
      <tr>
        <td height="60" align="center"><label>
          <input type="button" name="button3" id="button3" value="预览" />
          <input type="button" name="button3" id="button4" value="保存" onclick="saveproduct(this.form);"/>
          <input type="reset" name="button3" id="button6" value="取消" />
        </label></td>
      </tr>
    </table>
  </div>
</form>
</body>
</html>

